import java.util.Scanner;

public class StudentAction {
   public Student  inputData(){
       Scanner sc=new Scanner(System.in);
       System.out.println("请输入学号");
       String stuNo1=sc.nextLine();
       System.out.println("请输入是否继续");
       boolean flag=sc.nextBoolean();
       sc.nextLine();
       if(flag){
           System.out.println("输入姓名:");
           String b=sc.nextLine();
           System.out.println("输入性别:");
           String c=sc.nextLine();
           System.out.println("输入年龄");
           int d=sc.nextInt();
           sc.nextLine();
           return new Student(stuNo1,b,c,d);
       } else{
           return null;
       }
   }

    public int isExist(Student arg0){
       for(int i=0;i<StudentData.num;i++){
        if(arg0.equals(StudentData.getStudent(i))){
            return i;
        }
       }
        return -1;
    }
}
